<template>
  <div class="header">
    <div>欢迎来到布布一二世界</div>

    <div class="avatar">
      欢迎 {{ name }}
      <div class="demo-type">
        <div>
          <el-avatar
            src="https://cube.elemecdn.com/0/88/03b0d39583f48206768a7534e55bcpng.png"
          ></el-avatar>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: "Header",
  props: {},
  data() {
    return {
      name: sessionStorage.getItem("name"),
    };
  },
};
</script>

<style scoped>
.header {
  height: 150px;
  width: 100%;
  background-image: url(../assets/game.gif);
  background-position: 10% center;
  background-repeat: no-repeat;
  background-size: 20%;

  font-family: MicrosoftYaHei-Bold;
  font-size: 32px;
  color: #080a3f;
  font-weight: 700;
  line-height: 150px;
  /* padding-left: 16px; */
  text-align: center;

  position: relative;
}

.avatar {
  position: absolute;
  top: 0px;
  right: 20px;

  display: flex;

  font-size: 16px;
  color: #080a3f;
  font-weight: 700;
  line-height: 150px;
  /* padding-left: 16px; */
  text-align: center;
}
</style>
